import request from '@/utils/request'

const api = {
  addBatchRuleUrl: '/kc_batch_rule/add_batch_rule',
  getBatchRuleInfoUrl: '/kc_batch_rule/get_batch_rule_info',
  updateBatchRuleUrl: '/kc_batch_rule/update_batch_rule',
  getBatchRuleListUrl: '/kc_batch_rule/get_batch_rule_list',
}
export async function getBatchRuleListApi(params: Map<string, any>) {
  const res = await request({
    url: api.getBatchRuleListUrl,
    method: 'post',
    data: params,
  })
  return res
}

export async function updateBatchRuleApi(params: Map<string, any>) {
  const res = await request({
    url: api.updateBatchRuleUrl,
    method: 'post',
    data: params,
  })
  return res
}

export async function getBatchRuleInfoApi(params: Map<string, any>) {
  const res = await request({
    url: api.getBatchRuleInfoUrl,
    method: 'post',
    data: params,
  })
  return res
}

export async function addBatchRuleApi(params: Map<string, any>) {
  const res = await request({
    url: api.addBatchRuleUrl,
    method: 'post',
    data: params,
  })
  return res
}
